layui.define(['jquery', 'element', 'layer'], function(exports) {
	var $ = layui.jquery,
		layer = layui.layer;

	$(function() {
		//折线图
		var ordermove = echarts.init(document.getElementById('orderMove'));
		orderoptions = {
			tooltip: {
				trigger: 'axis'
			},
			legend: {
				data: ['订单数量', '用户数量']
			},
			toolbox: {
				show: true,
				right: '2%',
				feature: {
					magicType: {
						type: ['line', 'bar']
					}
				}
			},
			grid: {
				//show:true,
				left: '1%',
				right: '4%',
				bottom: '3%',
				containLabel: true,
				backgroundColor: 'rgba(238,238,238,0.4)'
			},
			xAxis: {
				type: 'category',
				boundaryGap: false,
				splitLine: {
					show: true,
					lineStyle: {
						color: '#f3f3f3'
					}
				},
				data: ['1-6', '1-7', '1-8', '1-9', '1-10', '1-13', '1-14']
			},
			yAxis: {
				type: 'value',
				splitLine: {
					show: true,
					lineStyle: {
						color: '#f3f3f3'
					}
				},
				min: 0,
				max: 1000
			},
			series: [{
					name: '订单数量',
					type: 'line',
					stack: '总量',
					symbolSize: 6,
					itemStyle: {
						normal: {
							color: '#cc0033',
						}
					},
					lineStyle: {
						normal: {
							color: '#cc0033'
						}
					},
					data: [120, 132, 101, 434, 90, 230, 210],
					markPoint: {
						data: [{
								type: 'max',
								name: '最大值'
							},
							{
								type: 'min',
								name: '最小值'
							}
						]
					}
				},
				{
					name: '用户数量',
					type: 'line',
					stack: '总量',
					symbolSize: 6,
					itemStyle: {
						normal: {
							color: '#4799FF',
						}
					},
					lineStyle: {
						normal: {
							color: '#4799FF',
						}
					},
					data: [710, 182, 191, 234, 290, 330, 110],
					markPoint: {
						data: [{
								type: 'max',
								name: '最大值'
							},
							{
								type: 'min',
								name: '最小值'
							}
						]
					}
				}
			]
		};
		ordermove.setOption(orderoptions);
	});
	exports('main', {});
});